home *** CD-ROM | disk | FTP | other *** search
/ STraTOS 1997 April & May / STraTOS 1 - 1997 April & May.iso / CD01 / INTERNET / SITES / LITTLE / P3SRC.ZIP / ATARI / CONFIG.H < prev    next >
Encoding:
C/C++ Source or Header  |  1997-01-21  |  4.6 KB  |  138 lines

  1. /****************************************************************************
  2. *                   source\msdos\config.h
  3. *
  4. *  This file contains the machine specific defines for a 32-bit protected
  5. *  mode msdos compile under several different compilers. 
  6. *
  7. *  from Persistence of Vision(tm) Ray Tracer
  8. *  Copyright 1996 Persistence of Vision Team
  9. *---------------------------------------------------------------------------
  10. *  NOTICE: This source code file is provided so that users may experiment
  11. *  with enhancements to POV-Ray and to port the software to platforms other
  12. *  than those supported by the POV-Ray Team.  There are strict rules under
  13. *  which you are permitted to use this file.  The rules are in the file
  14. *  named POVLEGAL.DOC which should be distributed with this file. If
  15. *  POVLEGAL.DOC is not available or for more info please contact the POV-Ray
  16. *  Team Coordinator by leaving a message in CompuServe's Graphics Developer's
  17. *  Forum.  The latest version of POV-Ray may be found there as well.
  18. *
  19. * This program is based on the popular DKB raytracer version 2.12.
  20. * DKBTrace was originally written by David K. Buck.
  21. * DKBTrace Ver 2.0-2.12 were written by David K. Buck & Aaron A. Collins.
  22. * Rev. 6/7/94
  23. *****************************************************************************/
  24.  
  25. #ifndef CONFIG_H
  26. #define CONFIG_H
  27.  
  28. /* Comment out the defines below if you are not using the fancy text 
  29.  * routines in MSDOSTXT.C or video in MSDOSVID.C
  30.  */
  31.  
  32. /*
  33. #define FANCY_TEXT 
  34. */
  35. #define FANCY_VIDEO
  36.  
  37. /*****************
  38.  *
  39.  * Note: These compiler specific defines should only contain items
  40.  * that are likely to affect the generic parts of POV-Ray.  Any video
  41.  * specific stuff belongs in MSDOSVID.C.  Any text specific stuff belongs
  42.  * in MSDOSTXT.C.  Any items common to video and text belongs in MSDOSALL.H.
  43.  ****************/
  44.  
  45. void main(int, char **);
  46. double fmod(double, double);
  47. #define COMPILER_VER ".tos.gcc.2.7.2"
  48.  
  49. #define PRECISION_TIMER_AVAILABLE 1
  50. #define PRECISION_TIMER_INIT ZTimerInit () ;
  51. #define PRECISION_TIMER_START LZTimerOn() ;
  52. #define PRECISION_TIMER_STOP LZTimerOff() ;
  53. #define PRECISION_TIMER_COUNT LZTimerCount() ;
  54.  
  55. #define START_TIME xtime(&tstart);     
  56. #define STOP_TIME xtime(&tstop);
  57.  
  58. /*
  59. #define START_TIME time(&tstart);     
  60. #define STOP_TIME time(&tstop);
  61. */
  62.  
  63. #include <compiler.h>
  64. #include <stdarg.h>
  65. #include <stdlib.h>
  66. #include <time.h>  
  67. #include <times.h>  
  68. #include <timeb.h>  
  69. #include <utime.h>  
  70.  
  71. /* Un comment at most one of these options
  72. #define MEM_TAG     - Enables memory tag debugging
  73. #define MEM_RECLAIM - Enables garbage collection
  74. */
  75.  
  76. #define MEM_TRACE   
  77. #define MEM_STATS 1    
  78.  
  79. #define FILENAME_SEPARATOR '\\'
  80.  
  81. #define EPSILON 1.0e-5
  82.  
  83. #define DEFAULT_OUTPUT_FORMAT   't'
  84. #define NEW_LINE_STRING "\r\n"
  85.  
  86. /* defines for machine-specific PaletteOption settings */
  87. #define NORMAL  '0'
  88. #define GREY    'G'
  89. #define HSV     '0'
  90. #define P_332   '3'
  91. #define HICOLOR 'H'             /* 16 bits/pixel "high" color */
  92. #define FULLCOLOR 'T'           /* 24 bits/pixel "true" color */
  93.  
  94. #define RENAME_FILE(orig,new) rename(orig,new)
  95.  
  96. void MSDOS_Startup(void);
  97. int MSDOS_System(char *s);
  98. void MSDOS_Process_Povray_Ini(char *s);
  99. void MSDOS_Process_Env(void);
  100. void MSDOS_Other_Credits(void);
  101.  
  102. #define STARTUP_POVRAY MSDOS_Startup();
  103. #define POV_SYSTEM(s) MSDOS_System(s);
  104. #define PROCESS_POVRAY_INI MSDOS_Process_Povray_Ini(argv[0]);
  105. #define READ_ENV_VAR MSDOS_Process_Env();
  106. #define PRINT_OTHER_CREDITS if (argc>1) {Print_Authors(); MSDOS_Other_Credits(); }
  107. #define CONST const
  108.  
  109. #define WAIT_FOR_KEYPRESS Crawcin();
  110. #define GET_KEY(x) { (x) = Crawcin(); }
  111. #define TEST_ABORT if (opts.Options & EXITENABLE) { if (Cconis()) { Stop_Flag = TRUE; Crawcin(); }}
  112. #define FINISH_POVRAY(n) exit(n);
  113.  
  114. #ifdef FANCY_VIDEO
  115.  
  116.  void V_Init (int w, int h, unsigned long v, unsigned char f); 
  117. /*
  118.  void V_Fin (void);
  119. */
  120.  void V_Close (void);
  121.  void V_Plot (int x, int y, unsigned char r, 
  122.   unsigned char g, unsigned char b);
  123.  void V_Rect (int x1, int x2, int y1, int y2, 
  124.   unsigned char r, unsigned char g, unsigned char b);
  125.  void V_Box (int x1, int x2, int y1, int y2, 
  126.   unsigned int r, unsigned int g, unsigned int b);
  127.  
  128.  #define POV_DISPLAY_FINISHED Display_Finished();
  129.  #define POV_DISPLAY_INIT(w,h,v,f) V_Init ((w), (h), (v), (f));
  130.  #define POV_DISPLAY_CLOSE V_Close();
  131.  #define POV_DISPLAY_PLOT(x,y,r,g,b,a) V_Plot((x),(y),(r),(g),(b));
  132.  #define POV_DISPLAY_PLOT_RECT(x1,x2,y1,y2,r,g,b,a) V_Rect((x1),(x2),(y1),(y2),(r),(g),(b));
  133.  #define POV_DISPLAY_PLOT_BOX(x1,x2,y1,y2,r,g,b,a) V_Box((x1),(x2),(y1),(y2),(r),(g),(b));
  134.  
  135. #endif
  136.  
  137. #endif
  138.